*** /home/kreskin/u0/barnett/Src/ease/src/lexan.l	Wed Mar  1 15:43:53 1989
--- lexan.l	Mon May  7 14:12:53 1990
***************
*** 59,78 ****
  	static char linbuf[BUFSIZ], *pc = linbuf;
  	char c;
  
- 
- 
- 
- 
  	/* initialize buffer: first call only */
  	if (*pc == '\0' && pc == linbuf) {
  		if (fgets(linbuf, BUFSIZ, yyin)==NULL)
  			return EOF;
!                 if (linbuf[0] == '#' )
!                     fprintf(yyout, "%s", linbuf);  /* echo input as comment */
!                 else
!                     fprintf(yyout, "# %s", linbuf);  /* echo input as comment */
! 
  	}
  	c = *pc++;
  	if (c == '\n') {
  		pc = linbuf;
--- 68,82 ----
  	static char linbuf[BUFSIZ], *pc = linbuf;
  	char c;
  
  	/* initialize buffer: first call only */
  	if (*pc == '\0' && pc == linbuf) {
  		if (fgets(linbuf, BUFSIZ, yyin)==NULL)
  			return EOF;
! 		/* echo input as comment */
! 		if (EchoInputAsComments) {
! 		    fprintf(yyout, "%s%s", (linbuf[0] == '#' ? "" : "# "), linbuf);
  		}
+ 	}
  	c = *pc++;
  	if (c == '\n') {
  		pc = linbuf;
***************
*** 79,90 ****
  		if (fgets(linbuf, BUFSIZ, yyin) == NULL)
  			*pc = EOF;
  		else
! 			/* echo input as comment except cpp comments */
!                     if (linbuf[0] == '#' )
!                         fprintf(yyout, "%s", linbuf);  /* echo input as comment */
!                     else
!                         fprintf(yyout, "# %s", linbuf);  /* echo input as comment */
  	}
  	return c;
  }
  
--- 83,94 ----
  		if (fgets(linbuf, BUFSIZ, yyin) == NULL)
  			*pc = EOF;
  		else
! 			/* echo input as comment (except cpp comments) */
! 			if (EchoInputAsComments) {
! 			    fprintf(yyout, "%s%s",
! 				(linbuf[0] == '#' ? "" : "# "), linbuf);
  			}
+ 	}
  	return c;
  }
  
***************
*** 103,109 ****
  	{ "Path",		MPATH },
  	{ "Recipient",		MRECIPIENT },
  	{ "Sender",		MSENDER },
- 	{ "asm",		ASM },
  	{ "bind",		BIND },
  	{ "canon",		CANON },
  	{ "class",		CLASS },
--- 107,112 ----
***************
*** 112,121 ****
  	{ "d_interactive",	DOPTI },
  	{ "d_queue",		DOPTQ },
  	{ "define",		DEFINE },
- 	{ "eval",		EVAL },
  	{ "f_addrw",		CCFLAG },
  	{ "f_arpa",		AAFLAG },
- 	{ "f_bsmtp",		BBFLAG },	/* IDA */
  	{ "f_date",		DDFLAG },
  	{ "f_dot",		XXFLAG },
  	{ "f_escape",		EEFLAG },
--- 115,122 ----
***************
*** 125,136 ****
  	{ "f_full",		XFLAG },
  	{ "f_llimit",		LLFLAG },
  	{ "f_locm",		LFLAG },
- 	{ "f_mail11",		HHFLAG },
  	{ "f_mesg",		MMFLAG },
  	{ "f_mult",		MFLAG },
  	{ "f_noreset",		SSFLAG },
  	{ "f_noufrom",		NFLAG },
- 	{ "f_relativize",	VVFLAG },
  	{ "f_retsmtp",		PFLAG },
  	{ "f_return",		PPFLAG },
  	{ "f_rfrom",		RFLAG },
--- 126,135 ----
***************
*** 159,171 ****
  	{ "match",		MATCH },
  	{ "next",		NEXT },
  	{ "o_alias",		AAOPT },
- 	{ "o_aliasfile",	YYOPT },
  	{ "o_bsub",		BBOPT },
  	{ "o_checkpoint",	CCOPT },
  	{ "o_delivery",		DOPT },
  	{ "o_dmuid",		UOPT },
  	{ "o_dnet",		NNOPT },
- 	{ "o_envelope",		SLOPT },
  	{ "o_ewait",		AOPT },
  	{ "o_flog",		SSOPT },
  	{ "o_fsmtp",		HHOPT },
--- 158,168 ----
***************
*** 174,183 ****
  	{ "o_hformat",		OOPT },
  	{ "o_loadnc",		XXOPT },
  	{ "o_loadq",		XOPT },
- 	{ "o_maxempty",		BOPT },
- 	{ "o_maxhops",		HOPT },
  	{ "o_newproc",		YYOPT },
- 	{ "o_nfs",		RROPT },	/* SunOS 4.0 */
  	{ "o_pmaster",		PPOPT },
  	{ "o_prifactor",	ZOPT },
  	{ "o_qdir",		QQOPT },
--- 171,177 ----
***************
*** 200,209 ****
  	{ "o_wizpass",		WWOPT },
  	{ "options",		OPTIONS },
  	{ "precedence",		PRECEDENCE },
- 	{ "quote",		QUOTE },
  	{ "readclass",		READCLASS },
  	{ "resolve",		RESOLVE },
- 	{ "resolved",		RESOLVED },
  	{ "retry",		RETRY },
  	{ "return",		RETURN },
  	{ "ruleset",		RULESET },
--- 194,201 ----
***************
*** 210,218 ****
  	{ "trusted",		TRUSTED },
  	{ "user",		USER },
  	{ "while",		IF },
- 	{ "ypalias",		YPALIAS },
- 	{ "ypmap",		YPMAP },
- 	{ "yppasswd",		YPPASSWD },
  };
  %}
  
--- 202,207 ----
***************
*** 221,231 ****
  
  [ \t\f]+			; 	/* discard whitepsace  */
  [\n]				Lcount++;
! ^\#[ \t]*[0-9]+[ \t]*\".*\"[ \t]*.*[\n]	{
! /*			        sscanf (yytext, "%*c%d%s", &Lcount, FNbuf); */
! 	                        yymark();
  			        }
! [A-Za-z_][A-Za-z0-9_-]*		{
  				register int l, h, m, r, c;
  
  				l = 0;
--- 210,219 ----
  
  [ \t\f]+			; 	/* discard whitepsace  */
  [\n]				Lcount++;
! ^\#[ \t]*[0-9]+[ \t]*\".*\"[ \t]*[\n]	{
! 			        sscanf (yytext, "%*c%d%s", &Lcount, FNbuf);
  			        }
! [A-Za-z][A-Za-z0-9_-]*		{
  				register int l, h, m, r, c;
  
  				l = 0;
***************
*** 292,305 ****
  						INch = input ();
  				}
  				}
- "/"				return (SLASH);
  [\\]?.				{
  				if (RMatch) {	/* in rulesets, return literal character */
  					yylval.ival = (yytext[0] == '\\') ? yytext[1] : yytext[0];
  					return (SEPCHAR);
- 
  				} else {
! 					PrintError ("Illegal delimiter character: (octal code) \\%03o", *yytext);
  				}
  				}
  %%
--- 280,292 ----
  						INch = input ();
  				}
  				}
  [\\]?.				{
  				if (RMatch) {	/* in rulesets, return literal character */
  					yylval.ival = (yytext[0] == '\\') ? yytext[1] : yytext[0];
  					return (SEPCHAR);
  				} else {
! 					ErrorReport ("Illegal delimiter character");
! 					printf (": (octal code) \\%03o\n", *yytext);
  				}
  				}
  %%
